package green.mapstore

/**
 * <p>Data store in the form of the map data structure.</p>
 * <p>Please note that @MapStore implementations do not need to be able to operate on the same data source
 * concurrently.</p>
 */
public interface MapStore {

  // MANIPULATION OPS

  void add(Object key, Object value)

  void addAll(Map<Object, Object> values)

  void delete(Object key)

  void clear()

  // DIAGNOSTIC OPS

  int size()

  boolean containsKey(Object key)

  // RETRIEVAL OPS

  Object get(Object key)

  Map<Object, Object> getAll()

  // LIFECYCLE OPS

  void init()

  void commit()

}